﻿using System;
using System.Data;
using Loki.Data;

namespace Luna.Data
{
    public abstract class LunaMapper<TDataEntity, TDataInterface> : EntityMapper<TDataEntity, TDataInterface, Guid>
        where TDataInterface : IDataEntity<Guid>
        where TDataEntity : TDataInterface
    {
        protected LunaMapper()
        {
            LogQueries = true;
        }

        protected override Func<IDataRecord, string, Guid> IDConverter
        {
            get { return DatabaseUtils.GetGuid; }
        }
    }
}